<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width,initial-scale=1,user-scalable=0, minimum-scale=1.0, maximum-scale=1.0">
</head>
<?
//每天记得来点一次 记录登录的账号有哪些
// if((date('H:i:s',$_SERVER['REQUEST_TIME'])<'23:50')) exit('你来晚了');
require_once("/var/www/html/new/conf/le.je");
$le=new go_sql();
$le->connect();
$date = date('Y-m-d',$_SERVER['REQUEST_TIME']);
// $date = '2015-11-17';
// $dat1e = '2015-10-18';
/*and lasttime<'$dat1e'*/
$sql = "select id,dname,dtype from pft_member where lasttime>'$date'  and group_id!=2";
$GLOBALS['le']->query($sql);
while($row=$GLOBALS['le']->fetch_assoc()){
    $r[] = $row;
}
file_put_contents($date.".log",json_encode($r));
$sql = "select count(*) from pft_member where lasttime>'$date' and group_id!=2";
$GLOBALS['le']->query($sql);
$row=$GLOBALS['le']->fetch_assoc();
echo "今天有{$row['count(*)']}个用户登录";
$GLOBALS['le']->close();
exit;
?>